// object to store loaded CSS chunks
var installedCssChunks = {
	<%- _installed_chunks %>
};

<%- ENSURE_CHUNK_HANDLERS %>.miniCss = function (chunkId, promises) {
	var cssChunks = <%- _css_chunks %>;
	if (installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId])
	else if (installedCssChunks[chunkId] !== 0 && cssChunks[chunkId])
		promises.push(
			installedCssChunks[chunkId] = loadStylesheet(chunkId).then(
				function () {
					installedCssChunks[chunkId] = 0;
				},
				function (e) {
					delete installedCssChunks[chunkId];
					throw e;
				}
			)
		)
}
